const http = require('http')
const fs = require('fs')

const server = http.createServer((request,response)=>{
    const data = fs.readFileSync(__dirname + '/09-table.html')
    response.end(data.toString())// 也可以不用toString()，直接response.end(data)，可以传递buffer
})

server.listen(
    3000,
    () => {
        console.log('启动服务。。。')
    }
)